Parity encoding input data before transmission by a wireless node may be performed by applying channel codes, e.g. Low-density parity-check (LDPC) codes. LDPC codes may be optimized for any block length and/or any code rate. LDPC codes may be described as a parity-check matrix (PCM). However, it is not efficient to use different PCMs for each alternative/combination of block lengths and code rates in communication systems. Instead, rate matching techniques are implemented to adapt a predefined code or PCM, selected from a set of predefined PCMs having different combinations of offered block lengths and code rates, e.g. through shortening, puncturing and repetition. As an example, LDPC codes for 802.11n as specified in IEEE Std 802.11-2012. Part 11: Wireless LAN Medium Access Control (MAC) and Physical Layer (PHY) Specifications, Sec. 20.3.11.7 and Annex F are specified with 12 mother codes (3 different block lengths and 4 different code rates). PCMs for all other block lengths and code rates needed are derived through shortening, puncturing and repetition applied to one of the 12 mother codes. Given a set of LDPC mother codes, it is not obvious which code to start from when applying shortening, puncturing and repetition. All of these rate matching techniques give codes that are suboptimal compared to dedicated LDPC codes optimized for a specific block length and rate. The conventional method for selection of mother codes, e.g. as specified in 802.11n, restricts the final code after shortening, puncturing, and repetition to have the same rate as one of the predefined mother codes. This is non-optimal and may result in reduced performance.
Thus there is a need to provide a solution which mitigates or solves the drawbacks and problems of conventional solutions.